
import {commonParams,options} from './config'
import jsonp from 'assets/js/jsonp'
// import axios from 'axios'


export function getRank(){
	
	const url = 'https://c.y.qq.com/v8/fcg-bin/fcg_myqq_toplist.fcg'
	
	var data = Object.assign({},commonParams,{
	    platform: 'h5',
	    uin: 0,
	    needNewCode: 1
	});
 
	return jsonp(url, data, options)
}

//https://c.y.qq.com/v8/fcg-bin/fcg_v8_toplist_cp.fcg?topid=4


export function getRankList(topid){
	
	const url = 'https://c.y.qq.com/v8/fcg-bin/fcg_v8_toplist_cp.fcg'
	
	var data = Object.assign({},commonParams,{
	    platform: 'h5',
	    uin: 0,
	    needNewCode: 1,
	    topid:topid
	});
 
	return jsonp(url, data, options)
}